﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using System.Drawing;
using Project.Model;

namespace Project.API.Models.GoodModels
{
    public class OrdersDto
    {
        [Key]
        public string Did { get; set; }

        public int? UserId { get; set; }

        public int? Gid { get; set; }

        [Column(TypeName = "date")]
        public DateTime CreateDate { get; set; }

        [Required]
        [StringLength(40)]
        public string OrderStatus { get; set; }
        public string Address { get; set; }

        public double TotalAmount { get; set; }

        public int OrderNumber { get; set; }

        [Column(TypeName = "text")]
        [Required]
        public string Notes { get; set; }
        
        public string userName { get; set; }   //用户名称

        [Required]
        [StringLength(50)]
        public string Goodsname { get; set; }   //商品名称

        public List<OrdersSpecDto> SpvList {  get; set; } //规格

        public string Images { get; set; } //商品图片
    }
    public class OrdersSpecDto {
        public string Specvalue { get; set; }
        public int Sid { get; set; }
        public string Did { get; set; }
        public int Gpvid { get; set; }
    }
}